package org.sky.tags;

import lombok.Data;
import lombok.EqualsAndHashCode;
import org.sky.util.NumberUtils;
import org.springframework.web.servlet.tags.RequestContextAwareTag;

/**
 * @author weifx
 * @Title: CustomerTags
 * @ProjectName springboot-platform
 * @Description: TODO{自定义数字转汉字标签}
 * @date 2019/3/28 9:47
 * @Version 1.0
 */
@Data
@EqualsAndHashCode(callSuper = false)
public class CustomerNumberToZHTags extends RequestContextAwareTag {
    private int value;
    @Override
    protected int doStartTagInternal() throws Exception {
        String bigNumber = NumberUtils.numToUpper2(value);
        pageContext.getOut().write(bigNumber);
        return EVAL_PAGE;
    }
}
